# Virtual Router Simulator 
#
# Copyright (C) 2009-2010 VRSim Project
# Author: Choonho Son <choonho@kt.com>
# URL: <http://vrsim.googlecode.com>
# For license information, see LICENSE.TXT
#

from xml.dom.minidom import parse,  getDOMImplementation

class XML:
    def __init__(self,  title):
        self.title = title
        #self.xml = None
        #self.root = None
        obj = getDOMImplementation()
        self.xml = obj.createDocument(None,  title,  None)
        self.root = self.xml.getElementsByTagName(title)[0]       
    
    """
    def getXML(self):
        return self.root
    """
    
    def getXMLString(self):
        return self.root.toxml()
        
    def printXML(self):
        return self.root.toxml()
        
    
